Integrand size = 21, antiderivative size = 157 \[ \int \cot ^6(c+d x) (a+b \tan (c+d x))^3 \, dx=-a \left (a^2-3 b^2\right ) x-\frac {a \left (a^2-3 b^2\right ) \cot (c+d x)}{d}+\frac {b \left (3 a^2-b^2\right ) \cot ^2(c+d x)}{2 d}+\frac {a \left (a^2-3 b^2\right ) \cot ^3(c+d x)}{3 d}-\frac {11 a^2 b \cot ^4(c+d x)}{20 d}+\frac {b \left (3 a^2-b^2\right ) \log (\sin (c+d x))}{d}-\frac {a^2 \cot ^5(c+d x) (a+b \tan (c+d x))}{5 d} \]
-a*(a^2-3*b^2)*x-a*(a^2-3*b^2)*cot(d*x+c)/d+1/2*b*(3*a^2-b^2)*cot(d*x+c)^2 /d+1/3*a*(a^2-3*b^2)*cot(d*x+c)^3/d-11/20*a^2*b*cot(d*x+c)^4/d+b*(3*a^2-b^ 2)*ln(sin(d*x+c))/d-1/5*a^2*cot(d*x+c)^5*(a+b*tan(d*x+c))/d
Result contains complex when optimal does not.
Time = 1.04 (sec) , antiderivative size = 152, normalized size of antiderivative = 0.97 \[ \int \cot ^6(c+d x) (a+b \tan (c+d x))^3 \, dx=-\frac {a \left (a^2-3 b^2\right ) \cot (c+d x)-\frac {1}{2} b \left (3 a^2-b^2\right ) \cot ^2(c+d x)-\frac {1}{3} a \left (a^2-3 b^2\right ) \cot ^3(c+d x)+\frac {3}{4} a^2 b \cot ^4(c+d x)+\frac {1}{5} a^3 \cot ^5(c+d x)-\frac {1}{2} (i a+b)^3 \log (i-\cot (c+d x))+\frac {1}{2} (i a-b)^3 \log (i+\cot (c+d x))}{d} \]
-((a*(a^2 - 3*b^2)*Cot[c + d*x] - (b*(3*a^2 - b^2)*Cot[c + d*x]^2)/2 - (a* (a^2 - 3*b^2)*Cot[c + d*x]^3)/3 + (3*a^2*b*Cot[c + d*x]^4)/4 + (a^3*Cot[c + d*x]^5)/5 - ((I*a + b)^3*Log[I - Cot[c + d*x]])/2 + ((I*a - b)^3*Log[I + Cot[c + d*x]])/2)/d)
Time = 1.14 (sec) , antiderivative size = 166, normalized size of antiderivative = 1.06, number of steps used = 17, number of rules used = 17, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.810, Rules used = {3042, 4048, 3042, 4111, 27, 3042, 4012, 3042, 4012, 25, 3042, 4012, 3042, 4014, 3042, 25, 3956}
Below are the steps used by Rubi to obtain the solution. The rule number used for the transformation is given above next to the arrow. The rules definitions used are listed below.
\(\displaystyle \int \cot ^6(c+d x) (a+b \tan (c+d x))^3 \, dx\) |
\(\Big \downarrow \) 3042 |
\(\displaystyle \int \frac {(a+b \tan (c+d x))^3}{\tan (c+d x)^6}dx\) |
\(\Big \downarrow \) 4048 |
\(\displaystyle \frac {1}{5} \int \cot ^5(c+d x) \left (11 b a^2-5 \left (a^2-3 b^2\right ) \tan (c+d x) a-b \left (4 a^2-5 b^2\right ) \tan ^2(c+d x)\right )dx-\frac {a^2 \cot ^5(c+d x) (a+b \tan (c+d x))}{5 d}\) |
\(\Big \downarrow \) 3042 |
\(\displaystyle \frac {1}{5} \int \frac {11 b a^2-5 \left (a^2-3 b^2\right ) \tan (c+d x) a-b \left (4 a^2-5 b^2\right ) \tan (c+d x)^2}{\tan (c+d x)^5}dx-\frac {a^2 \cot ^5(c+d x) (a+b \tan (c+d x))}{5 d}\) |
\(\Big \downarrow \) 4111 |
\(\displaystyle \frac {1}{5} \left (\int -5 \cot ^4(c+d x) \left (a \left (a^2-3 b^2\right )+b \left (3 a^2-b^2\right ) \tan (c+d x)\right )dx-\frac {11 a^2 b \cot ^4(c+d x)}{4 d}\right )-\frac {a^2 \cot ^5(c+d x) (a+b \tan (c+d x))}{5 d}\) |
\(\Big \downarrow \) 27 |
\(\displaystyle \frac {1}{5} \left (-5 \int \cot ^4(c+d x) \left (a \left (a^2-3 b^2\right )+b \left (3 a^2-b^2\right ) \tan (c+d x)\right )dx-\frac {11 a^2 b \cot ^4(c+d x)}{4 d}\right )-\frac {a^2 \cot ^5(c+d x) (a+b \tan (c+d x))}{5 d}\) |
\(\Big \downarrow \) 3042 |
\(\displaystyle \frac {1}{5} \left (-5 \int \frac {a \left (a^2-3 b^2\right )+b \left (3 a^2-b^2\right ) \tan (c+d x)}{\tan (c+d x)^4}dx-\frac {11 a^2 b \cot ^4(c+d x)}{4 d}\right )-\frac {a^2 \cot ^5(c+d x) (a+b \tan (c+d x))}{5 d}\) |
\(\Big \downarrow \) 4012 |
\(\displaystyle \frac {1}{5} \left (-5 \left (\int \cot ^3(c+d x) \left (b \left (3 a^2-b^2\right )-a \left (a^2-3 b^2\right ) \tan (c+d x)\right )dx-\frac {a \left (a^2-3 b^2\right ) \cot ^3(c+d x)}{3 d}\right )-\frac {11 a^2 b \cot ^4(c+d x)}{4 d}\right )-\frac {a^2 \cot ^5(c+d x) (a+b \tan (c+d x))}{5 d}\) |
\(\Big \downarrow \) 3042 |
\(\displaystyle \frac {1}{5} \left (-5 \left (\int \frac {b \left (3 a^2-b^2\right )-a \left (a^2-3 b^2\right ) \tan (c+d x)}{\tan (c+d x)^3}dx-\frac {a \left (a^2-3 b^2\right ) \cot ^3(c+d x)}{3 d}\right )-\frac {11 a^2 b \cot ^4(c+d x)}{4 d}\right )-\frac {a^2 \cot ^5(c+d x) (a+b \tan (c+d x))}{5 d}\) |
\(\Big \downarrow \) 4012 |
\(\displaystyle \frac {1}{5} \left (-5 \left (\int -\cot ^2(c+d x) \left (a \left (a^2-3 b^2\right )+b \left (3 a^2-b^2\right ) \tan (c+d x)\right )dx-\frac {a \left (a^2-3 b^2\right ) \cot ^3(c+d x)}{3 d}-\frac {b \left (3 a^2-b^2\right ) \cot ^2(c+d x)}{2 d}\right )-\frac {11 a^2 b \cot ^4(c+d x)}{4 d}\right )-\frac {a^2 \cot ^5(c+d x) (a+b \tan (c+d x))}{5 d}\) |
\(\Big \downarrow \) 25 |
\(\displaystyle \frac {1}{5} \left (-5 \left (-\int \cot ^2(c+d x) \left (a \left (a^2-3 b^2\right )+b \left (3 a^2-b^2\right ) \tan (c+d x)\right )dx-\frac {a \left (a^2-3 b^2\right ) \cot ^3(c+d x)}{3 d}-\frac {b \left (3 a^2-b^2\right ) \cot ^2(c+d x)}{2 d}\right )-\frac {11 a^2 b \cot ^4(c+d x)}{4 d}\right )-\frac {a^2 \cot ^5(c+d x) (a+b \tan (c+d x))}{5 d}\) |
\(\Big \downarrow \) 3042 |
\(\displaystyle \frac {1}{5} \left (-5 \left (-\int \frac {a \left (a^2-3 b^2\right )+b \left (3 a^2-b^2\right ) \tan (c+d x)}{\tan (c+d x)^2}dx-\frac {a \left (a^2-3 b^2\right ) \cot ^3(c+d x)}{3 d}-\frac {b \left (3 a^2-b^2\right ) \cot ^2(c+d x)}{2 d}\right )-\frac {11 a^2 b \cot ^4(c+d x)}{4 d}\right )-\frac {a^2 \cot ^5(c+d x) (a+b \tan (c+d x))}{5 d}\) |
\(\Big \downarrow \) 4012 |
\(\displaystyle \frac {1}{5} \left (-5 \left (-\int \cot (c+d x) \left (b \left (3 a^2-b^2\right )-a \left (a^2-3 b^2\right ) \tan (c+d x)\right )dx-\frac {a \left (a^2-3 b^2\right ) \cot ^3(c+d x)}{3 d}-\frac {b \left (3 a^2-b^2\right ) \cot ^2(c+d x)}{2 d}+\frac {a \left (a^2-3 b^2\right ) \cot (c+d x)}{d}\right )-\frac {11 a^2 b \cot ^4(c+d x)}{4 d}\right )-\frac {a^2 \cot ^5(c+d x) (a+b \tan (c+d x))}{5 d}\) |
\(\Big \downarrow \) 3042 |
\(\displaystyle \frac {1}{5} \left (-5 \left (-\int \frac {b \left (3 a^2-b^2\right )-a \left (a^2-3 b^2\right ) \tan (c+d x)}{\tan (c+d x)}dx-\frac {a \left (a^2-3 b^2\right ) \cot ^3(c+d x)}{3 d}-\frac {b \left (3 a^2-b^2\right ) \cot ^2(c+d x)}{2 d}+\frac {a \left (a^2-3 b^2\right ) \cot (c+d x)}{d}\right )-\frac {11 a^2 b \cot ^4(c+d x)}{4 d}\right )-\frac {a^2 \cot ^5(c+d x) (a+b \tan (c+d x))}{5 d}\) |
\(\Big \downarrow \) 4014 |
\(\displaystyle \frac {1}{5} \left (-5 \left (-b \left (3 a^2-b^2\right ) \int \cot (c+d x)dx-\frac {a \left (a^2-3 b^2\right ) \cot ^3(c+d x)}{3 d}-\frac {b \left (3 a^2-b^2\right ) \cot ^2(c+d x)}{2 d}+\frac {a \left (a^2-3 b^2\right ) \cot (c+d x)}{d}+a x \left (a^2-3 b^2\right )\right )-\frac {11 a^2 b \cot ^4(c+d x)}{4 d}\right )-\frac {a^2 \cot ^5(c+d x) (a+b \tan (c+d x))}{5 d}\) |
\(\Big \downarrow \) 3042 |
\(\displaystyle \frac {1}{5} \left (-5 \left (-b \left (3 a^2-b^2\right ) \int -\tan \left (c+d x+\frac {\pi }{2}\right )dx-\frac {a \left (a^2-3 b^2\right ) \cot ^3(c+d x)}{3 d}-\frac {b \left (3 a^2-b^2\right ) \cot ^2(c+d x)}{2 d}+\frac {a \left (a^2-3 b^2\right ) \cot (c+d x)}{d}+a x \left (a^2-3 b^2\right )\right )-\frac {11 a^2 b \cot ^4(c+d x)}{4 d}\right )-\frac {a^2 \cot ^5(c+d x) (a+b \tan (c+d x))}{5 d}\) |
\(\Big \downarrow \) 25 |
\(\displaystyle \frac {1}{5} \left (-5 \left (b \left (3 a^2-b^2\right ) \int \tan \left (\frac {1}{2} (2 c+\pi )+d x\right )dx-\frac {a \left (a^2-3 b^2\right ) \cot ^3(c+d x)}{3 d}-\frac {b \left (3 a^2-b^2\right ) \cot ^2(c+d x)}{2 d}+\frac {a \left (a^2-3 b^2\right ) \cot (c+d x)}{d}+a x \left (a^2-3 b^2\right )\right )-\frac {11 a^2 b \cot ^4(c+d x)}{4 d}\right )-\frac {a^2 \cot ^5(c+d x) (a+b \tan (c+d x))}{5 d}\) |
\(\Big \downarrow \) 3956 |
\(\displaystyle \frac {1}{5} \left (-5 \left (-\frac {a \left (a^2-3 b^2\right ) \cot ^3(c+d x)}{3 d}-\frac {b \left (3 a^2-b^2\right ) \cot ^2(c+d x)}{2 d}+\frac {a \left (a^2-3 b^2\right ) \cot (c+d x)}{d}-\frac {b \left (3 a^2-b^2\right ) \log (-\sin (c+d x))}{d}+a x \left (a^2-3 b^2\right )\right )-\frac {11 a^2 b \cot ^4(c+d x)}{4 d}\right )-\frac {a^2 \cot ^5(c+d x) (a+b \tan (c+d x))}{5 d}\) |
((-11*a^2*b*Cot[c + d*x]^4)/(4*d) - 5*(a*(a^2 - 3*b^2)*x + (a*(a^2 - 3*b^2 )*Cot[c + d*x])/d - (b*(3*a^2 - b^2)*Cot[c + d*x]^2)/(2*d) - (a*(a^2 - 3*b ^2)*Cot[c + d*x]^3)/(3*d) - (b*(3*a^2 - b^2)*Log[-Sin[c + d*x]])/d))/5 - ( a^2*Cot[c + d*x]^5*(a + b*Tan[c + d*x]))/(5*d)
3.5.44.3.1 Defintions of rubi rules used
Int[(a_)*(Fx_), x_Symbol] :> Simp[a Int[Fx, x], x] /; FreeQ[a, x] && !Ma tchQ[Fx, (b_)*(Gx_) /; FreeQ[b, x]]
Int[tan[(c_.) + (d_.)*(x_)], x_Symbol] :> Simp[-Log[RemoveContent[Cos[c + d *x], x]]/d, x] /; FreeQ[{c, d}, x]
Int[((a_.) + (b_.)*tan[(e_.) + (f_.)*(x_)])^(m_)*((c_.) + (d_.)*tan[(e_.) + (f_.)*(x_)]), x_Symbol] :> Simp[(b*c - a*d)*((a + b*Tan[e + f*x])^(m + 1)/ (f*(m + 1)*(a^2 + b^2))), x] + Simp[1/(a^2 + b^2) Int[(a + b*Tan[e + f*x] )^(m + 1)*Simp[a*c + b*d - (b*c - a*d)*Tan[e + f*x], x], x], x] /; FreeQ[{a , b, c, d, e, f}, x] && NeQ[b*c - a*d, 0] && NeQ[a^2 + b^2, 0] && LtQ[m, -1 ]
Int[((c_.) + (d_.)*tan[(e_.) + (f_.)*(x_)])/((a_.) + (b_.)*tan[(e_.) + (f_. )*(x_)]), x_Symbol] :> Simp[(a*c + b*d)*(x/(a^2 + b^2)), x] + Simp[(b*c - a *d)/(a^2 + b^2) Int[(b - a*Tan[e + f*x])/(a + b*Tan[e + f*x]), x], x] /; FreeQ[{a, b, c, d, e, f}, x] && NeQ[b*c - a*d, 0] && NeQ[a^2 + b^2, 0] && N eQ[a*c + b*d, 0]
Int[((a_.) + (b_.)*tan[(e_.) + (f_.)*(x_)])^(m_)*((c_.) + (d_.)*tan[(e_.) + (f_.)*(x_)])^(n_), x_Symbol] :> Simp[(b*c - a*d)^2*(a + b*Tan[e + f*x])^(m - 2)*((c + d*Tan[e + f*x])^(n + 1)/(d*f*(n + 1)*(c^2 + d^2))), x] - Simp[1 /(d*(n + 1)*(c^2 + d^2)) Int[(a + b*Tan[e + f*x])^(m - 3)*(c + d*Tan[e + f*x])^(n + 1)*Simp[a^2*d*(b*d*(m - 2) - a*c*(n + 1)) + b*(b*c - 2*a*d)*(b*c *(m - 2) + a*d*(n + 1)) - d*(n + 1)*(3*a^2*b*c - b^3*c - a^3*d + 3*a*b^2*d) *Tan[e + f*x] - b*(a*d*(2*b*c - a*d)*(m + n - 1) - b^2*(c^2*(m - 2) - d^2*( n + 1)))*Tan[e + f*x]^2, x], x], x] /; FreeQ[{a, b, c, d, e, f}, x] && NeQ[ b*c - a*d, 0] && NeQ[a^2 + b^2, 0] && NeQ[c^2 + d^2, 0] && GtQ[m, 2] && LtQ [n, -1] && IntegerQ[2*m]
Int[((a_.) + (b_.)*tan[(e_.) + (f_.)*(x_)])^(m_)*((A_.) + (B_.)*tan[(e_.) + (f_.)*(x_)] + (C_.)*tan[(e_.) + (f_.)*(x_)]^2), x_Symbol] :> Simp[(A*b^2 - a*b*B + a^2*C)*((a + b*Tan[e + f*x])^(m + 1)/(b*f*(m + 1)*(a^2 + b^2))), x ] + Simp[1/(a^2 + b^2) Int[(a + b*Tan[e + f*x])^(m + 1)*Simp[b*B + a*(A - C) - (A*b - a*B - b*C)*Tan[e + f*x], x], x], x] /; FreeQ[{a, b, e, f, A, B , C}, x] && NeQ[A*b^2 - a*b*B + a^2*C, 0] && LtQ[m, -1] && NeQ[a^2 + b^2, 0 ]
Time = 0.58 (sec) , antiderivative size = 152, normalized size of antiderivative = 0.97
method | result | size |
parallelrisch | \(\frac {30 \left (-3 a^{2} b +b^{3}\right ) \ln \left (\sec ^{2}\left (d x +c \right )\right )+60 \left (3 a^{2} b -b^{3}\right ) \ln \left (\tan \left (d x +c \right )\right )-12 \left (\cot ^{5}\left (d x +c \right )\right ) a^{3}-45 \left (\cot ^{4}\left (d x +c \right )\right ) a^{2} b +20 \left (a^{3}-3 a \,b^{2}\right ) \left (\cot ^{3}\left (d x +c \right )\right )+30 \left (3 a^{2} b -b^{3}\right ) \left (\cot ^{2}\left (d x +c \right )\right )+60 \left (-a^{3}+3 a \,b^{2}\right ) \cot \left (d x +c \right )-60 a d x \left (a^{2}-3 b^{2}\right )}{60 d}\) | \(152\) |
derivativedivides | \(\frac {-\frac {a^{3}}{5 \tan \left (d x +c \right )^{5}}-\frac {a \left (a^{2}-3 b^{2}\right )}{\tan \left (d x +c \right )}+b \left (3 a^{2}-b^{2}\right ) \ln \left (\tan \left (d x +c \right )\right )+\frac {a \left (a^{2}-3 b^{2}\right )}{3 \tan \left (d x +c \right )^{3}}-\frac {3 a^{2} b}{4 \tan \left (d x +c \right )^{4}}+\frac {b \left (3 a^{2}-b^{2}\right )}{2 \tan \left (d x +c \right )^{2}}+\frac {\left (-3 a^{2} b +b^{3}\right ) \ln \left (1+\tan ^{2}\left (d x +c \right )\right )}{2}+\left (-a^{3}+3 a \,b^{2}\right ) \arctan \left (\tan \left (d x +c \right )\right )}{d}\) | \(158\) |
default | \(\frac {-\frac {a^{3}}{5 \tan \left (d x +c \right )^{5}}-\frac {a \left (a^{2}-3 b^{2}\right )}{\tan \left (d x +c \right )}+b \left (3 a^{2}-b^{2}\right ) \ln \left (\tan \left (d x +c \right )\right )+\frac {a \left (a^{2}-3 b^{2}\right )}{3 \tan \left (d x +c \right )^{3}}-\frac {3 a^{2} b}{4 \tan \left (d x +c \right )^{4}}+\frac {b \left (3 a^{2}-b^{2}\right )}{2 \tan \left (d x +c \right )^{2}}+\frac {\left (-3 a^{2} b +b^{3}\right ) \ln \left (1+\tan ^{2}\left (d x +c \right )\right )}{2}+\left (-a^{3}+3 a \,b^{2}\right ) \arctan \left (\tan \left (d x +c \right )\right )}{d}\) | \(158\) |
norman | \(\frac {-\frac {a^{3}}{5 d}+\frac {a \left (a^{2}-3 b^{2}\right ) \left (\tan ^{2}\left (d x +c \right )\right )}{3 d}-\frac {a \left (a^{2}-3 b^{2}\right ) \left (\tan ^{4}\left (d x +c \right )\right )}{d}-a \left (a^{2}-3 b^{2}\right ) x \left (\tan ^{5}\left (d x +c \right )\right )-\frac {3 a^{2} b \tan \left (d x +c \right )}{4 d}+\frac {b \left (3 a^{2}-b^{2}\right ) \left (\tan ^{3}\left (d x +c \right )\right )}{2 d}}{\tan \left (d x +c \right )^{5}}+\frac {b \left (3 a^{2}-b^{2}\right ) \ln \left (\tan \left (d x +c \right )\right )}{d}-\frac {b \left (3 a^{2}-b^{2}\right ) \ln \left (1+\tan ^{2}\left (d x +c \right )\right )}{2 d}\) | \(178\) |
risch | \(-3 i a^{2} b x +i b^{3} x -a^{3} x +3 a \,b^{2} x -\frac {6 i b \,a^{2} c}{d}+\frac {2 i b^{3} c}{d}+\frac {12 i a \,b^{2} {\mathrm e}^{8 i \left (d x +c \right )}+\frac {28 i a^{3} {\mathrm e}^{2 i \left (d x +c \right )}}{3}-12 a^{2} b \,{\mathrm e}^{8 i \left (d x +c \right )}+2 b^{3} {\mathrm e}^{8 i \left (d x +c \right )}+12 i a^{3} {\mathrm e}^{6 i \left (d x +c \right )}-\frac {46 i a^{3}}{15}+24 a^{2} b \,{\mathrm e}^{6 i \left (d x +c \right )}-6 b^{3} {\mathrm e}^{6 i \left (d x +c \right )}+8 i a \,b^{2}+44 i a \,b^{2} {\mathrm e}^{4 i \left (d x +c \right )}-24 a^{2} b \,{\mathrm e}^{4 i \left (d x +c \right )}+6 b^{3} {\mathrm e}^{4 i \left (d x +c \right )}-\frac {56 i a^{3} {\mathrm e}^{4 i \left (d x +c \right )}}{3}-36 i a \,b^{2} {\mathrm e}^{6 i \left (d x +c \right )}+12 a^{2} b \,{\mathrm e}^{2 i \left (d x +c \right )}-2 b^{3} {\mathrm e}^{2 i \left (d x +c \right )}-28 i a \,b^{2} {\mathrm e}^{2 i \left (d x +c \right )}-6 i a^{3} {\mathrm e}^{8 i \left (d x +c \right )}}{d \left ({\mathrm e}^{2 i \left (d x +c \right )}-1\right )^{5}}+\frac {3 a^{2} b \ln \left ({\mathrm e}^{2 i \left (d x +c \right )}-1\right )}{d}-\frac {b^{3} \ln \left ({\mathrm e}^{2 i \left (d x +c \right )}-1\right )}{d}\) | \(364\) |
1/60*(30*(-3*a^2*b+b^3)*ln(sec(d*x+c)^2)+60*(3*a^2*b-b^3)*ln(tan(d*x+c))-1 2*cot(d*x+c)^5*a^3-45*cot(d*x+c)^4*a^2*b+20*(a^3-3*a*b^2)*cot(d*x+c)^3+30* (3*a^2*b-b^3)*cot(d*x+c)^2+60*(-a^3+3*a*b^2)*cot(d*x+c)-60*a*d*x*(a^2-3*b^ 2))/d
Time = 0.25 (sec) , antiderivative size = 173, normalized size of antiderivative = 1.10 \[ \int \cot ^6(c+d x) (a+b \tan (c+d x))^3 \, dx=\frac {30 \, {\left (3 \, a^{2} b - b^{3}\right )} \log \left (\frac {\tan \left (d x + c\right )^{2}}{\tan \left (d x + c\right )^{2} + 1}\right ) \tan \left (d x + c\right )^{5} + 15 \, {\left (9 \, a^{2} b - 2 \, b^{3} - 4 \, {\left (a^{3} - 3 \, a b^{2}\right )} d x\right )} \tan \left (d x + c\right )^{5} - 60 \, {\left (a^{3} - 3 \, a b^{2}\right )} \tan \left (d x + c\right )^{4} - 45 \, a^{2} b \tan \left (d x + c\right ) + 30 \, {\left (3 \, a^{2} b - b^{3}\right )} \tan \left (d x + c\right )^{3} - 12 \, a^{3} + 20 \, {\left (a^{3} - 3 \, a b^{2}\right )} \tan \left (d x + c\right )^{2}}{60 \, d \tan \left (d x + c\right )^{5}} \]
1/60*(30*(3*a^2*b - b^3)*log(tan(d*x + c)^2/(tan(d*x + c)^2 + 1))*tan(d*x + c)^5 + 15*(9*a^2*b - 2*b^3 - 4*(a^3 - 3*a*b^2)*d*x)*tan(d*x + c)^5 - 60* (a^3 - 3*a*b^2)*tan(d*x + c)^4 - 45*a^2*b*tan(d*x + c) + 30*(3*a^2*b - b^3 )*tan(d*x + c)^3 - 12*a^3 + 20*(a^3 - 3*a*b^2)*tan(d*x + c)^2)/(d*tan(d*x + c)^5)
Time = 2.28 (sec) , antiderivative size = 240, normalized size of antiderivative = 1.53 \[ \int \cot ^6(c+d x) (a+b \tan (c+d x))^3 \, dx=\begin {cases} \tilde {\infty } a^{3} x & \text {for}\: c = 0 \wedge d = 0 \\x \left (a + b \tan {\left (c \right )}\right )^{3} \cot ^{6}{\left (c \right )} & \text {for}\: d = 0 \\\tilde {\infty } a^{3} x & \text {for}\: c = - d x \\- a^{3} x - \frac {a^{3}}{d \tan {\left (c + d x \right )}} + \frac {a^{3}}{3 d \tan ^{3}{\left (c + d x \right )}} - \frac {a^{3}}{5 d \tan ^{5}{\left (c + d x \right )}} - \frac {3 a^{2} b \log {\left (\tan ^{2}{\left (c + d x \right )} + 1 \right )}}{2 d} + \frac {3 a^{2} b \log {\left (\tan {\left (c + d x \right )} \right )}}{d} + \frac {3 a^{2} b}{2 d \tan ^{2}{\left (c + d x \right )}} - \frac {3 a^{2} b}{4 d \tan ^{4}{\left (c + d x \right )}} + 3 a b^{2} x + \frac {3 a b^{2}}{d \tan {\left (c + d x \right )}} - \frac {a b^{2}}{d \tan ^{3}{\left (c + d x \right )}} + \frac {b^{3} \log {\left (\tan ^{2}{\left (c + d x \right )} + 1 \right )}}{2 d} - \frac {b^{3} \log {\left (\tan {\left (c + d x \right )} \right )}}{d} - \frac {b^{3}}{2 d \tan ^{2}{\left (c + d x \right )}} & \text {otherwise} \end {cases} \]
Piecewise((zoo*a**3*x, Eq(c, 0) & Eq(d, 0)), (x*(a + b*tan(c))**3*cot(c)** 6, Eq(d, 0)), (zoo*a**3*x, Eq(c, -d*x)), (-a**3*x - a**3/(d*tan(c + d*x)) + a**3/(3*d*tan(c + d*x)**3) - a**3/(5*d*tan(c + d*x)**5) - 3*a**2*b*log(t an(c + d*x)**2 + 1)/(2*d) + 3*a**2*b*log(tan(c + d*x))/d + 3*a**2*b/(2*d*t an(c + d*x)**2) - 3*a**2*b/(4*d*tan(c + d*x)**4) + 3*a*b**2*x + 3*a*b**2/( d*tan(c + d*x)) - a*b**2/(d*tan(c + d*x)**3) + b**3*log(tan(c + d*x)**2 + 1)/(2*d) - b**3*log(tan(c + d*x))/d - b**3/(2*d*tan(c + d*x)**2), True))
Time = 0.29 (sec) , antiderivative size = 158, normalized size of antiderivative = 1.01 \[ \int \cot ^6(c+d x) (a+b \tan (c+d x))^3 \, dx=-\frac {60 \, {\left (a^{3} - 3 \, a b^{2}\right )} {\left (d x + c\right )} + 30 \, {\left (3 \, a^{2} b - b^{3}\right )} \log \left (\tan \left (d x + c\right )^{2} + 1\right ) - 60 \, {\left (3 \, a^{2} b - b^{3}\right )} \log \left (\tan \left (d x + c\right )\right ) + \frac {60 \, {\left (a^{3} - 3 \, a b^{2}\right )} \tan \left (d x + c\right )^{4} + 45 \, a^{2} b \tan \left (d x + c\right ) - 30 \, {\left (3 \, a^{2} b - b^{3}\right )} \tan \left (d x + c\right )^{3} + 12 \, a^{3} - 20 \, {\left (a^{3} - 3 \, a b^{2}\right )} \tan \left (d x + c\right )^{2}}{\tan \left (d x + c\right )^{5}}}{60 \, d} \]
-1/60*(60*(a^3 - 3*a*b^2)*(d*x + c) + 30*(3*a^2*b - b^3)*log(tan(d*x + c)^ 2 + 1) - 60*(3*a^2*b - b^3)*log(tan(d*x + c)) + (60*(a^3 - 3*a*b^2)*tan(d* x + c)^4 + 45*a^2*b*tan(d*x + c) - 30*(3*a^2*b - b^3)*tan(d*x + c)^3 + 12* a^3 - 20*(a^3 - 3*a*b^2)*tan(d*x + c)^2)/tan(d*x + c)^5)/d
Leaf count of result is larger than twice the leaf count of optimal. 370 vs. \(2 (149) = 298\).
Time = 1.96 (sec) , antiderivative size = 370, normalized size of antiderivative = 2.36 \[ \int \cot ^6(c+d x) (a+b \tan (c+d x))^3 \, dx=\frac {6 \, a^{3} \tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right )^{5} - 45 \, a^{2} b \tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right )^{4} - 70 \, a^{3} \tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right )^{3} + 120 \, a b^{2} \tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right )^{3} + 540 \, a^{2} b \tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right )^{2} - 120 \, b^{3} \tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right )^{2} + 660 \, a^{3} \tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right ) - 1800 \, a b^{2} \tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right ) - 960 \, {\left (a^{3} - 3 \, a b^{2}\right )} {\left (d x + c\right )} - 960 \, {\left (3 \, a^{2} b - b^{3}\right )} \log \left (\tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right )^{2} + 1\right ) + 960 \, {\left (3 \, a^{2} b - b^{3}\right )} \log \left ({\left | \tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right ) \right |}\right ) - \frac {6576 \, a^{2} b \tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right )^{5} - 2192 \, b^{3} \tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right )^{5} + 660 \, a^{3} \tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right )^{4} - 1800 \, a b^{2} \tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right )^{4} - 540 \, a^{2} b \tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right )^{3} + 120 \, b^{3} \tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right )^{3} - 70 \, a^{3} \tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right )^{2} + 120 \, a b^{2} \tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right )^{2} + 45 \, a^{2} b \tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right ) + 6 \, a^{3}}{\tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right )^{5}}}{960 \, d} \]
1/960*(6*a^3*tan(1/2*d*x + 1/2*c)^5 - 45*a^2*b*tan(1/2*d*x + 1/2*c)^4 - 70 *a^3*tan(1/2*d*x + 1/2*c)^3 + 120*a*b^2*tan(1/2*d*x + 1/2*c)^3 + 540*a^2*b *tan(1/2*d*x + 1/2*c)^2 - 120*b^3*tan(1/2*d*x + 1/2*c)^2 + 660*a^3*tan(1/2 *d*x + 1/2*c) - 1800*a*b^2*tan(1/2*d*x + 1/2*c) - 960*(a^3 - 3*a*b^2)*(d*x + c) - 960*(3*a^2*b - b^3)*log(tan(1/2*d*x + 1/2*c)^2 + 1) + 960*(3*a^2*b - b^3)*log(abs(tan(1/2*d*x + 1/2*c))) - (6576*a^2*b*tan(1/2*d*x + 1/2*c)^ 5 - 2192*b^3*tan(1/2*d*x + 1/2*c)^5 + 660*a^3*tan(1/2*d*x + 1/2*c)^4 - 180 0*a*b^2*tan(1/2*d*x + 1/2*c)^4 - 540*a^2*b*tan(1/2*d*x + 1/2*c)^3 + 120*b^ 3*tan(1/2*d*x + 1/2*c)^3 - 70*a^3*tan(1/2*d*x + 1/2*c)^2 + 120*a*b^2*tan(1 /2*d*x + 1/2*c)^2 + 45*a^2*b*tan(1/2*d*x + 1/2*c) + 6*a^3)/tan(1/2*d*x + 1 /2*c)^5)/d
Time = 5.50 (sec) , antiderivative size = 166, normalized size of antiderivative = 1.06 \[ \int \cot ^6(c+d x) (a+b \tan (c+d x))^3 \, dx=\frac {\ln \left (\mathrm {tan}\left (c+d\,x\right )\right )\,\left (3\,a^2\,b-b^3\right )}{d}+\frac {\ln \left (\mathrm {tan}\left (c+d\,x\right )+1{}\mathrm {i}\right )\,{\left (b+a\,1{}\mathrm {i}\right )}^3}{2\,d}-\frac {{\mathrm {cot}\left (c+d\,x\right )}^5\,\left ({\mathrm {tan}\left (c+d\,x\right )}^2\,\left (a\,b^2-\frac {a^3}{3}\right )-{\mathrm {tan}\left (c+d\,x\right )}^4\,\left (3\,a\,b^2-a^3\right )-{\mathrm {tan}\left (c+d\,x\right )}^3\,\left (\frac {3\,a^2\,b}{2}-\frac {b^3}{2}\right )+\frac {a^3}{5}+\frac {3\,a^2\,b\,\mathrm {tan}\left (c+d\,x\right )}{4}\right )}{d}+\frac {\ln \left (\mathrm {tan}\left (c+d\,x\right )-\mathrm {i}\right )\,{\left (a+b\,1{}\mathrm {i}\right )}^3\,1{}\mathrm {i}}{2\,d} \]
(log(tan(c + d*x))*(3*a^2*b - b^3))/d + (log(tan(c + d*x) - 1i)*(a + b*1i) ^3*1i)/(2*d) + (log(tan(c + d*x) + 1i)*(a*1i + b)^3)/(2*d) - (cot(c + d*x) ^5*(tan(c + d*x)^2*(a*b^2 - a^3/3) - tan(c + d*x)^4*(3*a*b^2 - a^3) - tan( c + d*x)^3*((3*a^2*b)/2 - b^3/2) + a^3/5 + (3*a^2*b*tan(c + d*x))/4))/d